package base.generic.demo03;

import org.junit.Test;

/**
 * 泛型类中泛型的继承 测试
 */
public class TestCase {

    @Test
    public void testCase1(){
        Integer[] inums = {1,2,3,4,5};
        Generic<Integer> integerGeneric = new Generic<>(inums);
        System.out.println(integerGeneric.average());

        Double[] dnums ={1.0,2.0,3.0,4.0,5.0};
        Generic<Double> doubleGeneric = new Generic<>(dnums);
        System.out.println(doubleGeneric.average());
    }
}
